<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core"  prefix="c"%>
<%@ taglib uri="http://struts.apache.org/tags-html"  prefix="html"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>公告管理</title>
     <meta http-equiv="Content-Type" content="text/html;charset=GBK" />  
        <link href="styles.css" rel="stylesheet" type="text/css" />    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
	<style type="text/css">    
     /* CSS Document */   
     body {    
     font: normal 11px auto "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif;    
     color: #4f6b72;    
     }   
     a {    
    overflow:visible;   
    font-family:Tahoma,Helvetica,Arial,"宋体",sans-serif;   
    color:#0047D8;   
    }   
    a:hover{color: #9997D8;}   
    #mytable {    
    width: 700px;    
    padding: 0;    
    margin: 0;    
    }   
    caption {    
    padding: 0 0 5px 0;    
    width: 700px;         
    font:  18px Bold "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif;    
    text-align: center;    
    }   
    th {    
    font: bold 11px "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif;    
    color: #4f6b72;    
    border-right: 1px solid #C1DAD7;    
    border-bottom: 1px solid #C1DAD7;    
    border-top: 1px solid #C1DAD7;    
    letter-spacing: 2px;    
    text-transform: uppercase;    
    text-align: left;    
    padding: 6px 6px 6px 12px;    
    background: #CAE8EA url(images/bg_header.jpg) no-repeat;    
    }   
    th.nobg {    
    border-top: 0;    
    border-left: 0;    
    border-right: 1px solid #C1DAD7;    
    background: none;   
    }   
    td {    
    border-right: 1px solid #C1DAD7;    
    border-bottom: 1px solid #C1DAD7;    
    background: #fff;    
    font-size:11px;    
    padding: 6px 6px 6px 12px;    
    color: #4f6b72;    
    }   
    td.alt {    
    background: #F5FAFA;    
    color: #797268;    
    }   
  </style>
	<script type="text/javascript" language="java">
  function selectid(object){
	  var namelist=document.getElementsByName('lease');
	  for(var i=0;i<namelist.length;i++)
		  {
		  var e=namelist[i];
		  e.checked=object.checked;
		  }
  }
 
 </script>
  </head>
  
  <body>
  <html:form action="deletelease.do">
    <table width="550"  border="1" cellspacing="0" class="small">
  	<div id="everyReportCountSummary" style="text-align:left">  
              <table border=1 width="65%" height="200">  
                <caption>公告管理</caption>     
                <tr>
    <td colspan="5">
    
    <html:submit value="删除"></html:submit>
    <a href="admin/addlease.jsp" style="#000000">
    <img src="img/add.jpg">
    </a>
  </tr> 
                <tr>  
                    <th><html:checkbox property="leaseall" onclick="selectid(this)">全选</html:checkbox></th>
                    <th>标题</th>  
                    <th>发布时间</th> 
                    <th>内容</th> 
                    <th>修改</th>
                </tr>  
 
  <c:forEach items="${leaseList}"  var="leasees"  >
  <tr>
    <td ><label>
		<html:checkbox property="lease"  value="${leasees.leaseId}"/>
    </label></td>
    <td class="alt">${leasees.leaseName}</td>
    <td class="alt">${leasees.pageTime}</td>
    <td class="alt">${leasees.leaContent}</td>
    <td class="alt"><a href="selectLeaseById.do?leaseid=${leasees.leaseId}">修改</a></td>
  </tr>
   </c:forEach>
  <tr>
  	<td colspan="5" align="center">
  	<a href="maglease.do?pageNum=${firstPage}">首页</a>|<a href="maglease.do?pageNum=${proPage}">上一页</a>|<a href="maglease.do?pageNum=${nextPage}">下一页</a>|<a href="maglease.do?pageNum=${lastPage}">最后一页</a> 
  	</td>
  </tr>
  
 
</table>
</div>  
</html:form>
  </body>
</html>
